<?php 
/**
 * 
 * 男朋友 处理类
 * @author tanzhe
 *
 */
class boyfriend {
	
	public function get() { //获取男朋友信息
		$url = new Url();
	  	$key = $url->get('key');
		$boyfriendModel = new BoyfriendModel(); 
		$ret = $boyfriendModel->get($key);
		
		$callback = $url->get('jsonpcallback');
		Json::do_jsonp_encode($callback,$ret);
	}
	
	public function kiss() { //亲吻
		$url = new Url();
	  	$key = $url->get('key');
		$boyfriendModel = new BoyfriendModel(); 
		$ret = $boyfriendModel->kiss($key);
		
		$callback = $url->get('jsonpcallback');
		Json::do_jsonp_encode($callback,$ret);
	}
	
	public function chat() { //聊天
		$url = new Url();
	  	$key = $url->get('key');
		$boyfriendModel = new BoyfriendModel(); 
		$ret = $boyfriendModel->chat($key);
		
		$callback = $url->get('jsonpcallback');
		Json::do_jsonp_encode($callback,$ret);
	}
	
	public function urge() { //聊天
		$url = new Url();
	  	$key = $url->get('key');
		$boyfriendModel = new BoyfriendModel(); 
		$ret = $boyfriendModel->urge($key);
		
		$callback = $url->get('jsonpcallback');
		Json::do_jsonp_encode($callback,$ret);
	}
	
	public function breakup() { //分手
		$url = new Url();
	  	$key = $url->get('key');
		$boyfriendModel = new BoyfriendModel(); 
		$ret = $boyfriendModel->breakup($key);
		
		$callback = $url->get('jsonpcallback');
		Json::do_jsonp_encode($callback,$ret);
	}
	
	public function dating() { //约会
		$url = new Url();
	  	$key = $url->get('key');
	  	$type = $url->get('type');
		$boyfriendModel = new BoyfriendModel(); 
		$ret = $boyfriendModel->dating($key, $type);
		
		$callback = $url->get('jsonpcallback');
		Json::do_jsonp_encode($callback,$ret);
	}
	
	public function getGiftList() { //获取礼物列表
		$url = new Url();
	  	$key = $url->get('key');
	  	$shopId = $url->get('shopid');
		$boyfriendModel = new BoyfriendModel(); 
		$ret = $boyfriendModel->getGiftList($key, $shopId);
		
		$callback = $url->get('jsonpcallback');
		Json::do_jsonp_encode($callback,$ret);
	}
	
	public function buyGift() { //约会
		$url = new Url();
	  	$key = $url->get('key');
	  	$label = $url->get('label');
		$boyfriendModel = new BoyfriendModel(); 
		$ret = $boyfriendModel->buyGift($key, $label);
		
		$callback = $url->get('jsonpcallback');
		Json::do_jsonp_encode($callback,$ret);
	}
	
	public function getGiftLabel() { //
		$url = new Url();
	  	$key = $url->get('key');
	  	$quality = $url->get('quality');
		$boyfriendModel = new BoyfriendModel(); 
		$ret = $boyfriendModel->getGiftLabel($key, $quality);
		
		$callback = $url->get('jsonpcallback');
		//Json::do_jsonp_encode($callback,$ret);
	}
}
?>